package com.om39a.plm.parser;

import java.util.ArrayList;

/**
 * @author om39a
 * 
 */
public class PLMUser {

	private String userId;
	private String userName;
	private String userType;
	private String gender;
	private String age;
	private String place;
	private String dateJoined;
	private String noOfPosts;
	private String noOfHelpfulMarks;
	private String dataQualityStars;
	// User ID's will only be present in this list
	private ArrayList<String> followers;
	// User ID's will only be present in this list
	private ArrayList<String> following;
	// Individual Conditions will be available as a collection in this list
	private ArrayList<PLMUserCondition> conditions;

	private String followersProfileUrl;
	private String followingProfileUrl;

	public String getFollowersProfileUrl() {
		return followersProfileUrl;
	}

	public void setFollowersProfileUrl(String followersProfileUrl) {
		this.followersProfileUrl = followersProfileUrl;
	}

	public String getFollowingProfileUrl() {
		return followingProfileUrl;
	}

	public void setFollowingProfileUrl(String followingProfileUrl) {
		this.followingProfileUrl = followingProfileUrl;
	}

	@Override
	public String toString() {
		return "PLMUser [userId=" + userId + ", userName=" + userName
				+ ", userType=" + userType + ", gender=" + gender + ", age="
				+ age + ", place=" + place + ", dateJoined=" + dateJoined
				+ ", noOfPosts=" + noOfPosts + ", noOfHelpfulMarks="
				+ noOfHelpfulMarks + ", dataQualityStars=" + dataQualityStars
				+ ", followers=" + followers + ", following=" + following
				+ ", conditions=" + conditions + ", followersProfileUrl="
				+ followersProfileUrl + ", followingProfileUrl="
				+ followingProfileUrl + "]";
	}

	public String getUserId() {

		return userId;

	}

	public void setUserId(String userId) {

		this.userId = userId;

	}

	public String getUserName() {

		return userName;

	}

	public void setUserName(String userName) {

		this.userName = userName;

	}

	public String getUserType() {

		return userType;

	}

	public void setUserType(String userType) {

		this.userType = userType;

	}

	public String getGender() {

		return gender;

	}

	public void setGender(String gender) {

		this.gender = gender;

	}

	public String getAge() {

		return age;

	}

	public void setAge(String age) {

		this.age = age;

	}

	public String getPlace() {

		return place;

	}

	public void setPlace(String place) {

		this.place = place;

	}

	public String getDateJoined() {

		return dateJoined;

	}

	public void setDateJoined(String dateJoined) {

		this.dateJoined = dateJoined;

	}

	public String getNoOfPosts() {

		return noOfPosts;

	}

	public void setNoOfPosts(String noOfPosts) {

		this.noOfPosts = noOfPosts;

	}

	public String getNoOfHelpfulMarks() {

		return noOfHelpfulMarks;

	}

	public void setNoOfHelpfulMarks(String noOfHelpfulMarks) {

		this.noOfHelpfulMarks = noOfHelpfulMarks;

	}

	public String getDataQualityStars() {

		return dataQualityStars;

	}

	public void setDataQualityStars(String dataQualityStars) {

		this.dataQualityStars = dataQualityStars;

	}

	public ArrayList<String> getFollowers() {

		return followers;

	}

	public void setFollowers(ArrayList<String> followers) {

		this.followers = followers;

	}

	public ArrayList<String> getFollowing() {

		return following;

	}

	public void setFollowing(ArrayList<String> following) {

		this.following = following;

	}

	public ArrayList<PLMUserCondition> getConditions() {

		return conditions;

	}

	public void setConditions(ArrayList<PLMUserCondition> conditions) {

		this.conditions = conditions;

	}

	@Override
	public int hashCode() {

		final int prime = 31;

		int result = 1;

		result = prime * result + ((age == null) ? 0 : age.hashCode());

		result = prime * result

		+ ((conditions == null) ? 0 : conditions.hashCode());

		result = prime

		* result

		+ ((dataQualityStars == null) ? 0 : dataQualityStars.hashCode());

		result = prime * result

		+ ((dateJoined == null) ? 0 : dateJoined.hashCode());

		result = prime * result

		+ ((followers == null) ? 0 : followers.hashCode());

		result = prime * result

		+ ((following == null) ? 0 : following.hashCode());

		result = prime * result + ((gender == null) ? 0 : gender.hashCode());

		result = prime

		* result

		+ ((noOfHelpfulMarks == null) ? 0 : noOfHelpfulMarks.hashCode());

		result = prime * result

		+ ((noOfPosts == null) ? 0 : noOfPosts.hashCode());

		result = prime * result + ((place == null) ? 0 : place.hashCode());

		result = prime * result + ((userId == null) ? 0 : userId.hashCode());

		result = prime * result

		+ ((userName == null) ? 0 : userName.hashCode());

		result = prime * result

		+ ((userType == null) ? 0 : userType.hashCode());

		return result;

	}

	@Override
	public boolean equals(Object obj) {

		if (this == obj)

			return true;

		if (obj == null)

			return false;

		if (getClass() != obj.getClass())

			return false;

		PLMUser other = (PLMUser) obj;

		if (age == null) {

			if (other.age != null)

				return false;

		} else if (!age.equals(other.age))

			return false;

		if (conditions == null) {

			if (other.conditions != null)

				return false;

		} else if (!conditions.equals(other.conditions))

			return false;

		if (dataQualityStars == null) {

			if (other.dataQualityStars != null)

				return false;

		} else if (!dataQualityStars.equals(other.dataQualityStars))

			return false;

		if (dateJoined == null) {

			if (other.dateJoined != null)

				return false;

		} else if (!dateJoined.equals(other.dateJoined))

			return false;

		if (followers == null) {

			if (other.followers != null)

				return false;

		} else if (!followers.equals(other.followers))

			return false;

		if (following == null) {

			if (other.following != null)

				return false;

		} else if (!following.equals(other.following))

			return false;

		if (gender == null) {

			if (other.gender != null)

				return false;

		} else if (!gender.equals(other.gender))

			return false;

		if (noOfHelpfulMarks == null) {

			if (other.noOfHelpfulMarks != null)

				return false;

		} else if (!noOfHelpfulMarks.equals(other.noOfHelpfulMarks))

			return false;

		if (noOfPosts == null) {

			if (other.noOfPosts != null)

				return false;

		} else if (!noOfPosts.equals(other.noOfPosts))

			return false;

		if (place == null) {

			if (other.place != null)

				return false;

		} else if (!place.equals(other.place))

			return false;

		if (userId == null) {

			if (other.userId != null)

				return false;

		} else if (!userId.equals(other.userId))

			return false;

		if (userName == null) {

			if (other.userName != null)

				return false;

		} else if (!userName.equals(other.userName))

			return false;

		if (userType == null) {

			if (other.userType != null)

				return false;

		} else if (!userType.equals(other.userType))

			return false;

		return true;

	}

}
